#{extends 'main.html' /} #{set title:'Home' /}

<h1>Creation of a meeting</h1>
#{form @Application.process_create_event()}


<script>
	function refreshEvents(){
	$.ajax('/application/events_json').done(response);
	}
	function() response(events){
	$('tr').remove();
	for (var i=0; i<events.length; i++){
		 var name = '<td>'+events[i].name+'</td>
		 var row =$('<tr>'+name+'</tr>');
		$('table').append(row);
		}
	}
</script>

<label for="name"> Event's name <input type="text" name="name" />
</label>
<br />
<label for="date"> Jour de la réunion  <input type="date" name="begin" />
 <label for="heureBegin"> heure début réunion  <input type="time" name="heureBegin" />
			<label for="heureEnd"> heure Fin réunion  <input type="time" name="heureEnd" />
		</label>
	</label>
</label>  

<br>
<label for="auteur" >Autheur <input type="text" class="search-query" name=nom id = nom placeholder="nom"></label>
	
</br>

<br>
<label for="comments"> Commentaires  <textarea name="comments" id="comments"></textarea>  </label>
	
</br>

<label for="email"> Email utilisateur <input type="text" class="search-query" name=email id = email placeholder="Email"></label>
	
<input type="submit" value="Submit" class="btn btn-primary" /> 
	
#{/form}